<template>
	<view>
		<view class="page-header">
			<view class="flex-y-center" @click="gotoMap">
				<image src="@/static/img/dw.png" class="dwicon"></image>
				<view class="dwText">{{ address || '定位中...' }}</view>
			</view>
			<navigator url="/pages/search/search" class="page-search">
				<image src="@/static/img/sousuo.png" class="icon"></image>
				<view class="flex-grow-1">搜索</view>
			</navigator>
		</view>
		<view class="page-gradual">
			<!-- 轮播图 -->
			<view class="banner">
				<swiper class="banner-container" autoplay="true" circular="true" interval="3000" duration="1000"
					previous-margin="50rpx" next-margin="50rpx" @change="cIndex">
					<block v-for="(item,index) in banner" :key="index">
						<swiper-item>
							<image @click="jumpUrl(item);" class="slide-image"
								:class="[ currentIndex === index ? 'active':'' ]" :src="item.image">
							</image>
						</swiper-item>
					</block>
				</swiper>
			</view>
		</view>
		<!-- 导航 -->
		<view class="menu-navigation">
			<swiper style="height: 100%;">
				<swiper-item class="flex">
					<view v-for="(item,index) in nav_list" :key="index" class="menu-lg" @click="jumpUrl(item);">
						<image :src="item.image">
						</image>
						<view>{{ item.title }}</view>
					</view>
				</swiper-item>
			</swiper>
			<view class="add-c-d">
				<view style="display: inline-block;">
					<view class="add-f-s-1"></view>
				</view>
			</view>
		</view>
		<!-- 美团红包 -->
		<view class="flex-bet redPacket">
			<view @click="hongbao_url(hongbao.meituan_url);" class="item" v-if="hongbao.meituan_img">
				<image :src="hongbao.meituan_img" class="img" mode="widthFix"></image>
			</view>
			<view @click="hongbao_url(hongbao.elem_url);" class="item" v-if="hongbao.elem_img">
				<image :src="hongbao.elem_img" class="img" mode="widthFix"></image>
			</view>
		</view>
		<view style="height: 20upx;background-color: #f6f6f4"></view>
		<!--TODO 超值店铺暂时不要-->
		<view v-if="false">
			<navigator url="/pages/storeList/storeList?tag=3" hover-class="none" class="limit-store-container">
				<view class="page-listHeader">
					{{ tag_3.name }}
					<!-- <image class="header-icon" style="width: 96px;" :src="tag_3.image">
          </image>
          <view class="right">
            <text class="more-text">查看更多</text>
            <image style="width: 15px; height: 15px;" src="@/static/img/arrowBlack.png">
            </image>
          </view> -->
				</view>
				<view class="body">
					<scroll-view enable-flex="true" class="scroll-list">
						<div class="scroll-view">
							<div class="scroll-view" style="overflow-x: auto; overflow-y: hidden;">
								<div class="scroll-view-content">
									<view style="display: flex;">
										<view class="scroll-item" v-for="(item,index) in storeList" :key="index">
											<view class="item-row">
												<image class="scroll-img" mode="aspectFill" :src="item.image">
												</image>
												<text class="amount-text">满{{ item.pay_fee }}得{{ item.vip_cash_back }}
												</text>
											</view>
											<view class="item-row">
												<text class="scroll-name overflow-hidden">
													{{ item.name }}
												</text>
											</view>
											<view class="item-row">
												<text class="stock-text">还剩
													<text class="stock">{{ item.stock }}</text>
													份
												</text>
											</view>
										</view>

									</view>
								</div>
							</div>
						</div>
					</scroll-view>
				</view>
				<!-- <view class="body">
          <scroll-view enable-flex="true" class="scroll-list">
            <div class="scroll-view">
              <div class="scroll-view" style="overflow-x: auto; overflow-y: hidden;">
                <div class="scroll-view-content">
                  <view style="display: flex;">
                    <view class="scroll-item" v-for="(item,index) in storeList" :key="index">
                      <view class="item-row">
                        <image class="scroll-img" :src="item.image">
                        </image>
                        <text class="top-left">满{{item.pay_fee}}返{{item.cash_back}}
                        </text>
                        <text class="bottom-right">{{item.street}}
                        </text>
                      </view>
                      <view class="item-row">
                        <text class="scroll-name overflow-hidden">
                          {{item.name}}</text>
                      </view>
                      <view class="item-row flex-y-center">
                        <image src="@/static/img/meishi.png"
                          style="width: 10px;height: 9px;margin-right: 2px;"></image>
                        <view class="stock-text" style="color: #999;">剩余{{item.stock}}份</view>
                      </view>
                      <view class="item-row flex-x-end">
                        <view class="button">立即抢购</view>
                      </view>
                    </view>

                  </view>
                </div>
              </div>
            </div>
          </scroll-view>
        </view> -->
			</navigator>
			<view style="height: 20upx;background-color: #f6f6f4"></view>
		</view>
		<!-- 优选商家 -->
		<!-- 	<navigator url="/pages/storeList/storeList?tag=2" hover-class="none" class="limit-store-container">
        <view class="header" style="text-align: center;font-size: 18px;line-height:36px;display: block;">
          {{tag_2.name}} -->
		<!-- <image class="header-icon" style="width: 96px;" :src="tag_3.image">
    </image>
    <view class="right">
      <text class="more-text">查看更多</text>
      <image style="width: 15px; height: 15px;" src="@/static/img/arrowBlack.png">
      </image>
    </view> -->
		<!-- 			</view>
          <view class="body">
            <scroll-view enable-flex="true" class="scroll-list">
              <div class="scroll-view">
                <div class="scroll-view" style="overflow-x: auto; overflow-y: hidden;">
                  <div class="scroll-view-content">
                    <view style="display: flex;">
                      <view class="scroll-item" v-for="(item,index) in storeList2" :key="index">
                        <view class="item-row">
                          <image class="scroll-img" :src="item.image">
                          </image>
                          <text class="amount-text">满{{item.pay_fee}}得{{item.vip_cash_back}}
                          </text>
                        </view>
                        <view class="item-row">
                          <text class="scroll-name overflow-hidden">
                            {{item.name}}</text>
                        </view>
                        <view class="item-row">
                          <text class="stock-text">还剩<text class="stock">{{item.stock}}</text>
                            份</text>
                        </view>
                      </view>
                    </view>
                  </div>
                </div>
              </div>
            </scroll-view>
          </view>
        </navigator> -->
		<!-- <navigator url="/pages/storeList/storeList?tag=2" hover-class="none" class="recommend-store-container">
      <view class="header" style="text-align: center;font-size: 18px;line-height:36px;display: block;">
        {{tag_2.name}}
      </view>
      <view class="body">
        <view class="store-item" v-for="(item,index) in storeList2" :key="index">
          <view class="item-row">
            <image class="head-img" :src="item.image">
            </image>
            <text class="amount-text">满{{item.pay_fee}}得{{item.cash_back}}</text>
          </view>
          <view class="item-row">
            <text class="item-name overflow-hidden">{{item.name}}
            </text>
          </view>
          <view class="item-row">
            <text class="stock-text">还剩<text class="stock">{{item.stock}}</text>份</text>
          </view>
        </view>
      </view>
    </navigator> -->

		<view class="limit-store-container">
			<view class="page-otherHeader">
				<view class="page-listHeader">
					店铺列表
					<!-- {{ tag_1.name }} -->
				</view>
				<view class="variety-navigation">
					<view class="variety-text border-top">
						<view class="variety-navigation-icons flex-y-center">
							<view class="flex-y-center" style="margin-left: 9px;" @click="juliChange()">
								<view>距离</view>
								<image src="@/static/img/jiang.png" class="variety-image"
									:class="[juliup==true?'arrowup':'arrowdown']">
								</image>
							</view>
							<view class="flex-y-center" style="margin-left: 9px;" @click="jiageChange()">
								<view>价格</view>
								<image src="@/static/img/jiang.png" class="variety-image"
									:class="[jiageup==true?'arrowup':'arrowdown']">
								</image>
							</view>
						</view>
					</view>
				</view>
			</view>
		</view>
		<!--
    &lt;!&ndash; 分类 &ndash;&gt;
    <view class="variety-navigation">

      &lt;!&ndash; 	<view class="variety-swiper">
          <swiper class="menu-swiper h200" style="height: 100%;">

            <swiper-item v-for="(item1,index1) in cat_list" :key="index1"  class="flex swiper-iteme"
              style="position: absolute; width: 100%; height: 100%; transform: translate(100%, 0px) translateZ(0px);">
              <view class="menu-lg" @click="catChange(item2.id);"  v-for="(item2,index2) in item1" :key="index2">
                <image :src="item2.image">
                </image>
                <view class="">{{item2.name}}</view>
              </view>

            </swiper-item>

          </swiper>
          <view class="add-f-s">
            <view style="display: inline-block;">
              <view class="add-f-s-1"></view>
            </view>
            <view style="display: inline-block;">
              <view class="add-f-s-2"></view>
            </view>
          </view>
        </view> &ndash;&gt;
      <view class="variety-text border-top">
        <view class="variety-navigation-icons flex-y-center">
          <view class="flex-y-center" style="margin-right: 9px;" @click="juliChange()">
            <view>距离</view>
            <image src="@/static/img/jiang.png" class="variety-image"
                   :class="[juliup==true?'arrowup':'arrowdown']">
            </image>
          </view>
          <view class="flex-y-center" style="margin-right: 9px;" @click="jiageChange()">
            <view>价格</view>
            <image src="@/static/img/jiang.png" class="variety-image"
                   :class="[jiageup==true?'arrowup':'arrowdown']">
            </image>
          </view>
        </view>
      </view>
    </view>-->
		<!-- 商家列表 -->
		<view>
			<!--      <view class="header"-->
			<!--            style="text-align: center;font-size: 18px;line-height:36px;display: block;margin-bottom: 10px;">-->
			<!--        {{ tag_1.name }}-->
			<!--      </view>-->

			<view class="page-storeList">
				<view class="page-storeItem" v-for="(item,index) in data.data_list" :key="index"
					@click="storeTap(index)">
					<image class="storeItem-pic" :src="item.image" mode="aspectFill"></image>
					<view class="storeItem-child">
						<view class="child-title">{{ item.name }}</view>
						<!-- <view class="child-address">
              <image class="address-icon" mode="widthFix" src="@/static/img/address-gray-ico.png"></image>
              <view class="address-text">{{ item.address }}</view>
            </view> -->
						<!-- <view class="child-vip">
              <view class="vip-icon">
                <image class="icon-pic" src="/static/img/vipIndex.png"></image>
              </view>
              <view class="vip-text">开通VIP享{{ item.pay_fee }}奖{{ item.vip_cash_back }}</view>
            </view> -->
						<view class="child-one">
							<view class="one-left">
								<view class="left-type" v-if="item.platform==='meituan'">美团</view>
								<view class="left-type left-type--elm" v-if="item.platform==='eleme'">饿了么</view>
								<view class="left-label">可报名{{ item.open_start }} - {{ item.open_end }}</view>
							</view>
							<view class="one-distance">{{ item.distance }}</view>
						</view>
						<view class="child-bottom">
							<view class="bottom-text">实付{{ item.pay_fee }}奖{{ item.vip_cash_back }}</view>
							<view class="bottom-btn">
								<view class="btn-text">抢单</view>
								<view class="btn-progress">
									<view class="progress-bar"
										:style="'width: ' + (item.stock / (item.total_stock * 1)) * 100 + '%'"></view>
								</view>
							</view>
						</view>
					</view>
				</view>
			</view>

			<view class="store-list">
				<!--        <view class="store-item" v-for="(item,index) in data.data_list" :key="index" @click="storeTap(index)">-->
				<!--          <view class="goods_brand" style="background-color: rgb(255, 215, 5);"-->
				<!--                v-if="item.platform=='meituan'">-->
				<!--            <image src="@/static/img/meituan1.png">-->
				<!--            </image>-->
				<!--            <text class="name">美团</text>-->
				<!--          </view>-->
				<!--          <view class="goods_brand" style="background-color: rgb(33, 149, 255);"-->
				<!--                v-if="item.platform=='eleme'">-->
				<!--            <image src="@/static/img/elm1.png">-->
				<!--            </image>-->
				<!--            <text class="name">饿了么</text>-->
				<!--          </view>-->
				<!--          <view style="padding: 9px 12px;position: relative;overflow: hidden;z-index: 7;background: #fff;">-->
				<!--            <view class="rules-num" v-if="item.activity_count>1">-->
				<!--              <text><span>活动数{{ item.activity_count }}</span></text>-->
				<!--            </view>-->
				<!--            <view class="head-item border-bottom info-item">-->
				<!--              <view class="item-left">-->
				<!--                <view class="mask" v-if="item.open_buy=='0'">-->
				<!--                  <image src="@/static/img/weizhifu.png" class="mask-img">-->
				<!--                  </image>-->
				<!--                </view>-->
				<!--                <view class="mask" v-if="item.stock<=0">-->
				<!--                  <image src="@/static/img/out-of-stock.png" class="mask-img">-->
				<!--                  </image>-->
				<!--                </view>-->
				<!--                <image class="head-img" :src="item.image">-->
				<!--                </image>-->
				<!--              </view>-->
				<!--              <view class="item-right">-->
				<!--                <view class="item">-->
				<!--                  <view class="title">{{ item.name }}</view>-->
				<!--                </view>-->
				<!--                <view class="item">-->
				<!--                  <view>还剩-->
				<!--                    <text class="stock-text">-->
				<!--                      {{ item.stock }}-->
				<!--                    </text>-->
				<!--                    份-->
				<!--                  </view>-->
				<!--                  <view class="progress">-->
				<!--                    <progress :percent="item.percent" activeColor="rgb(255, 150, 42)"-->
				<!--                              stroke-width="8" border-radius="16"-->
				<!--                              backgroundColor="rgba(255, 150, 42, 0.5)">-->
				<!--                    </progress>-->

				<!--                  </view>-->
				<!--                </view>-->
				<!--                <view class="item">-->
				<!--                  <view class="distance-text">{{ item.distance ? '距离：' + item.distance : '' }}</view>-->
				<!--                  <view class="time-region">可报名 {{ item.open_start }}-{{ item.open_end }}</view>-->
				<!--                </view>-->
				<!--              </view>-->
				<!--            </view>-->
				<!--            <view class="head-item border-bottom cashback-item">-->
				<!--              <view class="text">非会员满-->
				<!--                <text class="amount">{{ item.pay_fee }}</text>-->
				<!--                奖-->
				<!--                <text class="amount">{{ item.cash_back }}</text>-->
				<!--              </view>-->
				<!--              <view class="text">会员满-->
				<!--                <text class="amount">{{ item.pay_fee }}</text>-->
				<!--                奖-->
				<!--                <text class="amount">{{ item.vip_cash_back }}</text>-->
				<!--              </view>-->
				<!--            </view>-->
				<!--            <view class="head-item border-bottom address-item">-->
				<!--              <image class="icon" src="@/static/img/address-gray-ico.png">-->
				<!--              </image>-->
				<!--              <view class="address-text">{{ item.address }}</view>-->
				<!--            </view>-->
				<!--          </view>-->
				<!--        </view>-->
			</view>

			<view style="text-align:center;margin-top:120rpx" v-if="data.no_list">
				<view style="color:#444">暂无数据</view>
			</view>
			<view class="flex-y-center flex-x-center"
				style="text-align: center;height: 74rpx;color: #888;font-size: 9pt" v-if="!data.no_list&&data.no_more">
				没有更多了~
			</view>
			<view style="text-align: center;height: 174rpx;color: #888;font-size: 9pt"
				class="flex-y-center flex-x-center" v-if="!data.no_list&&!data.no_more">
				加载中...
			</view>

		</view>
		<my-kefu></my-kefu>
	</view>
</template>

<script>
	// var jweixin = require('jweixin-module')
	import myKefu from '../../pages/publicService/publicService.vue';
	// const QQMapWX = require('../../utils/qqmap-wx-jssdk.min.js');
	import {
		getStoreList,
		getWxConfig,
		getIndexData,
		save_addr
	} from '../../apirequest/api.js';

	export default {
		components: {
			myKefu: myKefu
		},
		data() {
			return {
				lock: 0,
				address: '',
				lat: '',
				lng: '',
				distance: '',
				banner: [],
				nav_list: [],
				cat_list: [],
				currentIndex: 0,
				tag_1: [],
				tag_2: [],
				tag_3: [],
				// 一元霸王餐商家
				storeList: [],
				// 优选商家
				storeList2: [],
				// 全部商家
				storeList3: [],
				juliup: false,
				jiageup: false,
				cat_id: 0,
				sort: 1,
				data: {
					data_list: [],
					no_list: !1,
					no_more: !1,
					current_page: 0,
					loading_more: !0,
				},
				hongbao: [],
				is_map: false,
				province: '',
				city: '',
				district: ''
			}
		},

		/**
		 * 页面上拉触底事件的处理函数
		 */
		onReachBottom: function(t) {
			var o = this;
			o.loadDataList(function() {
				o.data.loading_more = !0;
			});
		},

		onLoad(options) {
			console.log("options", options);
			let that = this;
			that.loadDataList(function() {
				that.data.loading_more = !0;
			});
			if (options.pid) {
				uni.setStorageSync('parent_id', options.pid);
			} else {
				//uni.setStorageSync('parent_id', 0);
			}
			that.loadData();
			//?name=我的位置&latng=22.547,114.085947&addr=深圳市&city=深圳市&module=locationPicker#/
			let latng = that.getUrlParam('latng');
			let address = that.getUrlParam('name');
			let url = that.urlDelP(window.location.href);
			window.history.replaceState(null, '', url);
			if (latng) {
				let latng_arr = latng.split(',');
				console.log(address)
				uni.setStorageSync('longitude', latng_arr[1] || '');
				uni.setStorageSync('latitude', latng_arr[0] || '');
				uni.setStorageSync('address', address);
				that.lat = latng_arr[0] || '';
				that.lng = latng_arr[1] || '';
				that.address = address;
				that.data = {
					data_list: [],
					no_list: !1,
					no_more: !1,
					current_page: 0,
					loading_more: !0,
				}
				that.loadTagStore2();
				that.loadTagStore3();
				that.loadDataList();
			} else {
				// that.dingwei();
				that.getLoca();
			}
		},
		onShow() {
			// uni.setStorageSync('token', 'cc46eab2-aaca-489f-a77a-7c93ebef26c1');
			// uni.setStorageSync('old_code', '041RgV000G1bFQ1yRz000VBufp3RgV0p');
		},
		methods: {
			//判断图片是否存在
			CheckImgExists(url) {
				let ImgObj = new Image();
				ImgObj.src = url;
				console.log(ImgObj.width, "----")
				//存在图片
				if (ImgObj.width > 0 && ImgObj.height > 0) {
					return url;
				} else {
					return require('@/static/img/noPic.png');
				}
			},
			getLoca() {
				let that = this;
				uni.getLocation({
					type: 'gcj02',
					success: (res) => {
						that.getLocal(res.latitude, res.longitude, function() {
							console.log(
								'resresresresresresresresresresresresresresresresresresresresresresres',
								res)
							that.lat = res.latitude;
							that.lng = res.longitude;
							uni.setStorageSync('longitude', res.longitude);
							uni.setStorageSync('latitude', res.latitude);
							that.loadTagStore2();
							that.loadTagStore3();
							that.loadDataList();
						}, 1);
					},
					fail: (err) => {
						// 失败 回调
						uni.showToast({
							title: '定位失败，请手动定位',
							icon: 'error'
						});
					}
				})
			},
			dingwei: function() {
				let that = this;
				let url = window.location.href; // 链接一定要获取当前页面的完整链接，否则会一直报签名错误导致分享失败
				getWxConfig({
					url: encodeURI(location.href)
				}).then((res) => {
					if (res.code == 1) {
						// #ifdef MP-WEIXIN

						uni.getLocation({
							success(res) {
								if (!res.latitude || !res.longitude) {
									uni.showToast({
										title: '定位失败，请手动定位',
										icon: 'error'
									});
									setTimeout(function() {
										/* uni.navigateTo({
										  url:'/pages/map/map'
										}); */
										that.gotoMap();
									}, 1000);
									return;
								}
								that.getLocal(res.latitude, res.longitude, function() {
									that.lat = res.latitude;
									that.lng = res.longitude;
									uni.setStorageSync('longitude', res.longitude);
									uni.setStorageSync('latitude', res.latitude);
									that.loadTagStore2();
									that.loadTagStore3();
									that.loadDataList();
								});
							}
						})
						// #endif
						// #ifdef H5
						jweixin.config({
							debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来，若要查看传入的参数，可以在pc端打开，参数信息会通过log打出，仅在pc端时才会打印。
							appId: res.data.appId,
							timestamp: res.data.timestamp,
							nonceStr: res.data.nonceStr,
							signature: res.data.signature,
							jsApiList: ['getLocation']
						});
						jweixin.ready(function() {
							jweixin.getLocation({
								success: function(res) {
									console.log("jweixin", res);
									if (!res.latitude || !res.longitude) {
										uni.showToast({
											title: '定位失败，请手动定位',
											icon: 'error'
										});
										setTimeout(function() {
											/* uni.navigateTo({
											  url:'/pages/map/map'
											}); */
											that.gotoMap();
										}, 1000);
										return;
									}
									that.getLocal(res.latitude, res.longitude, function() {
										that.lat = res.latitude;
										that.lng = res.longitude;
										uni.setStorageSync('longitude', res
											.longitude);
										uni.setStorageSync('latitude', res
											.latitude);
										that.loadTagStore2();
										that.loadTagStore3();
										that.loadDataList();
									});
								},
								cancel: function(res) {
									uni.showToast({
										title: '用户拒绝授权获取地理位置',
										icon: 'error'
									});
								}
							});
						});
						jweixin.error(function(res) {
							// config信息验证失败会执行error函数，如签名过期导致验证失败，具体错误信息可以打开config的debug模式查看，也可以在返回的res参数中查看，对于SPA可以在这里更新签名。
							console.log('验证失败');
							console.log(res);
						});
						// #endif
					}
				});
			},
			getUrlParam(name) {
				var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
				var r = window.location.search.substr(1).match(reg);
				console.log(r);
				if (r != null) return decodeURI(r[2]);
				return null;
			},
			//跳转到地图
			gotoMap() {
				var host = window.location.protocol + "//" + window.location.host + "/h5";
				window.location.href = 'https://apis.map.qq.com/tools/locpicker?search=1&type=0&backurl=' + host +
					'&key=KJKBZ-PRNK2-S4HUQ-CF4BG-MS6HT-5HBJA&referer=%E9%A5%AD%E5%93%81%E4%B8%89%E5%9B%BD';
			},
			//删除url的所有参数
			urlDelP(url) {
				var urlArr = url.split('?');
				if (urlArr.length > 1) {
					var query = urlArr[1];
					var obj = {}
					var urlte = urlArr[0] + '?' + JSON.stringify(obj).replace(/[\"\{\}]/g, "").replace(/\:/g, "=").replace(
						/\,/g, "&");
					return urlte;
				} else {
					return url;
				};
			},

			hongbao_url(url) {
				if (url) {
					window.location.href = url;
				}
			},
			getMapLocation() {
				uni.navigateTo({
					url: '/pages/map/map'
				});
				return;
				let that = this;
				uni.chooseLocation({
					success: (res) => {
						console.log(res);
						uni.setStorageSync('longitude', res.longitude);
						uni.setStorageSync('latitude', res.latitude);
						uni.setStorageSync('address', res.name);
						that.data = {
							data_list: [],
							no_list: !1,
							no_more: !1,
							current_page: 0,
							loading_more: !0,
						}
						that.lat = res.latitude;
						that.lng = res.longitude;

						that.address = res.name;
						that.getLocal(res.latitude, res.longitude, function() {

							that.loadTagStore2();
							that.loadTagStore3();
							that.loadDataList();
						});

					},
					fail: () => {
						// 如果用uni.chooseLocation没有获取到地理位置，则需要获取当前的授权信息，判断是否有地理授权信息
						uni.getSetting({
							success: (res) => {
								console.log(res);
								var status = res.authSetting;
								if (!status['scope.userLocation']) {
									// 如果授权信息中没有地理位置的授权，则需要弹窗提示用户需要授权地理信息
									uni.showModal({
										title: "是否授权当前位置",
										content: "需要获取您的地理位置，请确认授权，否则地图功能将无法使用",
										success: (tip) => {
											if (tip.confirm) {
												// 如果用户同意授权地理信息，则打开授权设置页面，判断用户的操作
												uni.openSetting({
													success: (data) => {
														// 如果用户授权了地理信息在，则提示授权成功
														if (data
															.authSetting[
																'scope.userLocation'
															] === true
														) {
															uni.showToast({
																title: "授权成功",
																icon: "success",
																duration: 1000
															})
															// 授权成功后，然后再次chooseLocation获取信息
															uni.chooseLocation({
																success: (
																	res
																) => {
																	console
																		.log(
																			"详细地址",
																			res
																		);
																	uni.setStorageSync(
																		'longitude',
																		res
																		.longitude
																	);
																	uni.setStorageSync(
																		'latitude',
																		res
																		.latitude
																	);
																	uni.setStorageSync(
																		'address',
																		res
																		.name
																	);
																	that.data = {
																		data_list: [],
																		no_list:
																			!
																			1,
																		no_more:
																			!
																			1,
																		current_page: 0,
																		loading_more:
																			!
																			0
																	}
																	that.lat =
																		res
																		.latitude;
																	that.lng =
																		res
																		.longitude;

																	that.address =
																		res
																		.name;
																	that.getLocal(
																		res
																		.latitude,
																		res
																		.longitude,
																		function() {

																			that
																				.loadTagStore2();
																			that
																				.loadTagStore3();
																			that
																				.loadDataList();
																		}
																	);
																}
															})
														} else {
															uni.showToast({
																title: "授权失败",
																icon: "none",
																duration: 1000
															})
														}
													}
												})
											}
										}
									})
								}
							},
							fail: (res) => {
								uni.showToast({
									title: "调用授权窗口失败",
									icon: "none",
									duration: 1000
								})
							}
						})
					}
				});
			},
			jumpUrl(item) {
				if (item.url.match('/pages/')) {
					uni.navigateTo({
						url: item.url,
					});
				} else if (parseInt(item.links_id) == 1 && item.url) {
					window.location.href = item.url;
				}
				if (parseInt(item.links_id) > 0 && item.links) {
					let url = item.links.url;
					if (parseInt(item.param_id) > 0) {
						url = url + item.param_id;
					}
					console.log(url)
					uni.navigateTo({
						url: '' + url + '',
					});
				}
			},
			// 获取当前地理位置
			getLocal(latitude, longitude, callback, type = 0) {
				console.log('7777777777777777777777777')
				var data = {
					location: latitude + "," + longitude,
					/*换成自己申请的key*/
					key: "YLGBZ-AMC6P-FWNDR-L7L4U-CECQO-T6BVX",
					// key: "KJKBZ-PRNK2-S4HUQ-CF4BG-MS6HT-5HBJA",
					get_poi: 0,
					output: 'jsonp',
				}
				var url = "https://apis.map.qq.com/ws/geocoder/v1/?";
				var that = this;
				//jsonp请求
				this.$jsonp(url, data).then(res => {
						console.log('+++++++++++', res);
						if (type == 1) {
							that.address = "我的位置";
						} else {
							that.address = res.result.address_component.street;
						}

						that.province = res.result.address_component.province
						that.city = res.result.address_component.city
						that.district = res.result.address_component.district
						uni.setStorageSync('address', that.address);
						save_addr({
							province: res.result.address_component.province,
							city: res.result.address_component.city,
							district: res.result.address_component.district
						}).then((res) => {
							if (res.code == 1) {

							}
						}).catch(err => {
							console.log(err)
						})
						callback && callback(res);
					})
					.catch(error => {
						console.log(error);
					})
			},

			//获取数据
			loadData: function() {
				getIndexData({}).then((res) => {
					if (res.code == 1) {
						this.banner = res.data.banner;
						this.cat_list = res.data.cat_list;
						this.nav_list = res.data.nav_list;
						//this.storeList = res.data.storeList;
						//this.storeList2 = res.data.storeList2;
						this.tag_1 = res.data.tag_1;
						this.tag_2 = res.data.tag_2;
						this.tag_3 = res.data.tag_3;
						this.hongbao = res.data.hongbao;
					}
				}).catch(err => {
					console.log(err)
				})

			},

			//一元秒杀
			loadTagStore3: function() {
				var o = this;
				let longitude = uni.getStorageSync('longitude');
				let latitude = uni.getStorageSync('latitude');
				if (!longitude || !longitude) {
					return;
				}
				var page = 1;
				var data = {
					page: page,
					latitude: latitude,
					longitude: longitude,
					category_id: 0,
					juliup: o.juliup ? 1 : 0,
					jiageup: o.jiageup ? 1 : 0,
					sort: o.sort,
					tag_id: 3,
					province: this.province,
					city: this.city,
					district: this.district
				}
				getStoreList(data).then((res) => {
					if (res.code == 1) {
						this.storeList = res.data.data;
					}
				}).catch(err => {
					console.log(err)
				})

			},

			//优选商家
			loadTagStore2: function() {
				var o = this;
				let longitude = uni.getStorageSync('longitude');
				let latitude = uni.getStorageSync('latitude');
				if (!longitude || !longitude) {
					return;
				}
				var page = 1;
				var data = {
					page: page,
					latitude: latitude,
					longitude: longitude,
					category_id: 0,
					juliup: o.juliup ? 1 : 0,
					jiageup: o.jiageup ? 1 : 0,
					sort: o.sort,
					tag_id: 2,
					province: this.province,
					city: this.city,
					district: this.district
				}
				getStoreList(data).then((res) => {
					if (res.code == 1) {
						this.storeList2 = res.data.data;
					}
				}).catch(err => {
					console.log(err)
				})

			},

			//获取数据列表
			loadDataList: function(f) {
				var o = this;
				let longitude = uni.getStorageSync('longitude');
				let latitude = uni.getStorageSync('latitude');

				if (!longitude || !latitude) {
					return;
				}
				if (o.lock) {
					return;
				}
				if (o.data.no_list || o.data.no_more) "function" == typeof t && f();
				else {
					var page = (o.data.current_page || 0) + 1;
					var data = {
						page: page,
						latitude: latitude,
						longitude: longitude,
						category_id: o.cat_id,
						juliup: o.juliup ? 1 : 0,
						jiageup: o.jiageup ? 1 : 0,
						sort: o.sort,
						tag_id: 1,
						province: this.province,
						city: this.city,
						district: this.district
					}
					o.lock = 1;
					console.log(o.lock)
					getStoreList(data).then((t) => {
						if (t.code == 1) {
							if (1 == t.data.current_page && !t.data.data.length) {
								o.data.no_list = !0;
								o.data.loading_more = !1
							}
							if (t.data.data && t.data.data.length) {
								o.data.data_list = o.data.data_list || [];
								o.data.data_list = o.data.data_list.concat(t.data.data),
									o.data.current_page = page;
							}
							if (!t.data.has_more) {
								o.data.no_more = !0;
							}

						} else {
							uni.showToast({
								title: '网络繁忙',
								icon: 'error'
							})
						}
						o.lock = 0;
					});
				}
			},
			storeTap(index) {
				let this_item = this.data.data_list[index];
				if (!this_item) {
					return;
				}
				if (parseInt(this_item.open_buy) == 0) {
					let time = this_item.open_start + "-" + this_item.open_end;
					uni.showToast({
						icon: 'none',
						title: '未到报名时间，报名时间' + time,
						duration: 2000
					});

				} else if (parseInt(this_item.stock) <= 0) {
					uni.showToast({
						icon: 'none',
						title: '今日名额已抢光',
						duration: 2000
					})
				} else {
					this.distance = this_item.distance;
					uni.navigateTo({
						url: '/pages/details/details?id=' + this_item.store_id
					})
				}

			},
			cIndex(e) {
				this.currentIndex = e.detail.current
			},
			catChange(id) {
				this.cat_id = id;
				this.data = {
					data_list: [],
					no_list: !1,
					no_more: !1,
					current_page: 0,
					loading_more: !0,
				}
				this.loadDataList();
			},
			juliChange() {
				if (this.juliup == false) {
					this.juliup = true
				} else {
					this.juliup = false
				}
				this.sort = 1
				this.data = {
					data_list: [],
					no_list: !1,
					no_more: !1,
					current_page: 0,
					loading_more: !0,
				}
				this.loadDataList();
			},
			jiageChange() {
				if (this.jiageup == false) {
					this.jiageup = true
				} else {
					this.jiageup = false
				}
				this.sort = 2
				this.data = {
					data_list: [],
					no_list: !1,
					no_more: !1,
					current_page: 0,
					loading_more: !0,
				}
				this.loadDataList();
			},
		}
	}
</script>

<style lang="scss" scoped>
	page {
		background: #FFFFFF;
		font-size: 0.75rem;
	}

	html,
	page {
		background-color: #FFFFFF;
	}

	.page-gradual {
		padding-top: 30upx;
		background-image: linear-gradient(#ff8546 30%, #ffb130 50%, transparent);
	}

	.page-header {
		background: #ff8546;
		color: #fff;
		position: sticky;
		padding: 25upx;
		font-size: 0.95rem;
		width: 100%;
		z-index: 99;
		top: 0;
		left: 0;
		display: flex;
		align-items: center;
		justify-content: space-between;
		box-sizing: border-box;

		.dwicon {
			width: 40upx;
			height: 40upx;
			margin-right: 10upx;
			flex-shrink: 0;
		}

		.dwText {
			display: -webkit-box;
			-webkit-line-clamp: 1;
			-webkit-box-orient: vertical;
			overflow: hidden;
			word-break: break-all;
		}

		.icon {
			width: 30upx;
			height: 30upx;
			margin-left: 8upx;
		}
	}

	.page-search {
		flex-shrink: 0;
		display: flex;
		align-items: center;
		justify-content: flex-start;
		border-radius: 40upx;
		padding: 10upx 20upx;
		background-color: rgba(255, 255, 255, 0.3);
		font-size: 28rpx;
		color: #FFFFFF;
		margin-left: 30upx;

		.icon {
			width: 30upx;
			height: 30upx;
			margin-right: 10upx;
		}
	}

	.banner {
		height: 320rpx;
		width: 100%;
		display: flex;
		flex-direction: row;
		z-index: 999;
	}

	.banner .banner-container {
		width: 100%;
		height: 350rpx;
	}

	.banner .slide-image {
		position: absolute;
		height: 260rpx;
		width: 98%;
		border-radius: 30rpx;
		z-index: 5;
		opacity: 0.7;
		/*透明度*/
		top: 6%;
	}

	.banner .active {
		opacity: 1;
		z-index: 10;
		height: 320rpx;
		width: 98%;
		border-radius: 30rpx;
		top: 0%;
		transition: all 0.2s ease-in 0s;
	}


	.overflow-hidden {
		width: auto;
		overflow: hidden;
		text-overflow: ellipsis;
		display: -webkit-box;
		-webkit-box-orient: vertical;
		-webkit-line-clamp: 1
			/* 这里设置需要显示几行文本 */
		;
	}

	.recommend-store-container {
		background-color: #fff;
		margin: 9px 14px;
		font-size: 24rpx;
		border-radius: 9px
	}

	.recommend-store-container .header {
		display: flex;
		justify-content: space-between;
		align-items: center;
		padding: 9px;
		border-radius: 9px 9px 0 0;
		background: linear-gradient(180deg, #fff0e9 0, #fff)
	}

	.recommend-store-container .header .left .header-icon {
		height: 14px
	}

	.recommend-store-container .header .right {
		display: flex;
		align-items: center
	}

	.recommend-store-container .header .right .more-text {
		color: #bec1c7
	}

	.recommend-store-container .body {
		display: flex;
		flex-wrap: wrap;
		justify-content: space-between;
		padding: 0 9px
	}

	.recommend-store-container .body .store-item {
		display: flex;
		flex-flow: column;
		position: relative;
	}

	.recommend-store-container .body .store-item .item-row {
		margin-bottom: 4px;
		position: relative
	}

	.recommend-store-container .body .store-item .item-row .head-img {
		width: 153px;
		height: 115px;
		border-radius: 7px
	}

	.recommend-store-container .body .store-item .item-row .item-name {
		width: 153px;
		font-size: 28rpx;
		;
		font-weight: 700
	}

	.recommend-store-container .body .store-item .item-row .stock-text {
		font-size: 10px
	}

	.recommend-store-container .body .store-item .item-row .stock {
		color: #f96456
	}

	.recommend-store-container .body .store-item .item-row .amount-text {
		font-size: 24rpx;
		color: #fff;
		border-radius: 0 7px 0 7px;
		background: linear-gradient(270deg, #ff8826 0, #ed3066);
		position: absolute;
		padding: 2px 4px;
		text-align: center;
		bottom: 0;
		left: 0
	}

	.variety-navigation {
		margin: 9px 14px;
		background-color: #fff;
		border-radius: 9px
	}

	.variety-navigation .variety-swiper {
		height: 86px;
		background-color: #fff;
		font-size: 24rpx;
		border-radius: 9px;
		padding: 7px 0
	}

	.variety-navigation .variety-swiper .menu-lg {
		width: 20%;
		display: flex;
		flex-flow: column;
		align-items: center;
	}

	.variety-navigation .variety-swiper .menu-lg image {
		width: 48px;
		height: 48px;
		border-radius: 9px
	}

	.variety-navigation .variety-swiper .menu-lg .active {
		color: #f42f2f
	}

	.variety-navigation .variety-swiper .add-f-s {
		text-align: center;
		position: relative;
		left: 0;
		right: 0;
		top: -19px
	}

	.add-f-s-1 {
		width: 14px;
		height: 7px;
		border-radius: 15px;
		background-color: #ff8546;
	}

	.add-f-s-2 {
		width: 7px;
		height: 7px;
		border-radius: 50%;
		background-color: rgba(253, 211, 41, .5);
		margin: 0px 2px;
	}

	.variety-text {
		padding: 14px;
		color: #afb0b1;
		font-size: 12px
	}

	.variety-text .arrowup {
		-webkit-transform: rotate(180deg);
		transform: rotate(180deg)
	}

	.variety-text .variety-image {
		margin: 0px 4px;
		width: 12px;
		height: 12px
	}

	.commodity {
		margin: 9px 14px;
		background-color: #fff;
		border-radius: 9px
	}

	/* 主题色 */
	.meituan {
		color: #333 !important;
		background-color: #ff8546
	}

	.elem {
		color: #fff !important;
		background-color: #00a9e9
	}

	.amount {
		color: #f96456;
		font-weight: 700;
		margin: 0 2px
	}

	.store-list {
		display: flex;
		flex-flow: column;
	}

	.page-storeList {
		box-sizing: border-box;
	}

	.page-storeItem {
		display: flex;
		justify-content: flex-start;
		align-items: flex-start;
		box-sizing: border-box;
		padding: 30rpx;

		.storeItem-pic {
			width: 160rpx;
			height: 160rpx;
			flex-shrink: 0;
			border-radius: 20rpx;
			overflow: hidden;
			background-color: #f7f7f7;
		}

		.storeItem-child {
			width: 100%;
			font-size: 28rpx;
			color: #999999;
			margin-left: 20rpx;

			.child-title {
				font-size: 30rpx;
				font-weight: bold;
				color: #333333;
				display: -webkit-box;
				-webkit-line-clamp: 1;
				-webkit-box-orient: vertical;
				overflow: hidden;
				word-break: break-all;
			}

			.child-one {
				display: flex;
				align-items: center;
				justify-content: space-between;
				margin-top: 20rpx;

				.one-left {
					display: flex;
					align-items: center;
					justify-content: flex-start;
					font-size: 24rpx;

					.left-type {
						border: 2rpx solid #fdd900;
						background-color: #fdd900;
						padding: 4rpx 10rpx;
						border-radius: 10rpx;
						color: #333333;
						margin-right: 10rpx;
					}

					.left-type--elm {
						color: #fff;
						border-color: #02b6fd;
						background-color: #02b6fd;
					}

					.left-label {
						font-size: 26rpx;
						border: 2rpx solid #ff8546;
						color: #ff8546;
						border-radius: 10rpx;
						padding: 2rpx 10rpx;
					}
				}
			}

			.child-vip {
				display: inline-flex;
				justify-content: flex-start;
				align-items: center;
				margin-top: 20rpx;

				.vip-icon {
					width: 40rpx;
					height: 40rpx;
					margin-right: -10rpx;
					display: inline-flex;
					align-items: center;
					justify-content: center;
					border: 2rpx solid #666666;
					background-color: #333333;
					border-radius: 50%;
					position: relative;
					z-index: 1;

					.icon-pic {
						width: 70%;
						height: 70%;
					}
				}

				.vip-text {
					padding: 2rpx 20rpx;
					background-color: #333333;
					border: 2rpx solid #666666;
					font-size: 20rpx;
					color: #fee09e;
					border-radius: 0 40rpx 40rpx 0;
				}
			}

			.child-address {
				display: flex;
				align-items: center;
				justify-content: flex-start;
				font-size: 28rpx;
				color: #666666;
				margin-top: 20rpx;

				.address-icon {
					width: 36rpx;
					height: 36rpx;
					margin-right: 10rpx;
					flex-shrink: 0;
				}

				.address-text {
					display: -webkit-box;
					-webkit-line-clamp: 1;
					-webkit-box-orient: vertical;
					overflow: hidden;
					word-break: break-all;
				}
			}

			.child-bottom {
				display: flex;
				align-items: center;
				justify-content: space-between;
				box-sizing: border-box;
				background-color: #ff8546;
				border-radius: 10rpx;
				margin-top: 20rpx;
				overflow: hidden;

				.bottom-text {
					font-size: 30rpx;
					color: #FFFFFF;
					padding: 0 30rpx;
				}

				.bottom-btn {
					background-color: #333333;
					color: #fee09e;
					font-size: 28rpx;
					padding: 20rpx 40rpx 20rpx 40rpx;
					text-align: center;
					transform: skewX(-20deg) translateX(20rpx);
					border-left: 8rpx solid #FFFFFF;

					.btn-text {
						display: inline-block;
						transform: skewX(20deg);
					}

					.btn-progress {
						width: 150rpx;
						height: 10rpx;
						border-radius: 10rpx;
						background-color: rgba(255, 255, 255, 0.5);
						margin-top: 10rpx;
						transform: skewX(20deg);
						position: relative;
						overflow: hidden;

						.progress-bar {
							width: 50%;
							height: 100%;
							border-radius: 10rpx;
							background-color: #fee09e;
						}
					}
				}
			}
		}
	}

	.store-list .store-item {
		border-radius: 9px;
		background-color: #fff;
		margin: 0 40px 9px 14px;
		// padding: 9px 12px;
		position: relative;
		z-index: 8;
		background: #fff;
		/* 信息项 */
		/* 返现项 */
		/* 更多项 */
		/* 地址项 */
		/* 底部项 */
	}

	.store-list .store-item .goods_brand {
		width: 43px;
		border-radius: 0px 7px 7px 0px;
		position: absolute;
		top: 0px;
		right: -31px;
		z-index: 7;
		height: 100%;
	}

	.store-list .store-item .goods_brand image {
		width: 21px;
		height: 21px;
		margin-top: 9px;
		margin-left: 18px;
	}

	.store-list .store-item .goods_brand .name {
		display: block;
		width: 16px;
		position: absolute;
		top: 38px;
		right: 8px;
		line-height: 1.4em;
		word-wrap: break-word;
		font-size: 16px;
		font-weight: 600;
		color: #fff;
	}

	.store-list .store-item .head-item {
		display: flex;
		padding: 4px 0
	}

	.store-list .store-item .rules-num {
		position: absolute;
		background: linear-gradient(270deg, #ec5151 0, #ff5e3c 45%, #ffb15f);
		color: #fff;
		font-size: 9px;
		padding: 2px 14px;
		-webkit-transform: rotate(45deg);
		transform: rotate(45deg);
		top: 7px;
		right: -15px
	}

	.store-list .store-item .info-item {
		padding-top: 0
	}

	.store-list .store-item .info-item .item-left {
		position: relative
	}

	.store-list .store-item .info-item .item-left .region-name {
		position: absolute;
		top: -2px;
		right: -1px;
		color: #fff;
		font-size: 24rpx;
		border-radius: 15px 0 0 15px;
		width: 42px;
		height: 15px;
		text-align: center
	}

	.store-list .store-item .info-item .item-left .mask {
		width: 100%;
		height: 57px;
		border-radius: 7px;
		background-color: rgba(0, 0, 0, .7);
		position: absolute;
		z-index: 99;
		display: flex;
		align-items: center;
		justify-content: center
	}

	.store-list .store-item .info-item .item-left .mask .mask-img {
		width: 57px;
		height: 28px
	}

	.store-list .store-item .info-item .item-left .head-img {
		width: 76px;
		height: 76px;
		display: block;
		border-radius: 9px
	}

	.store-list .store-item .info-item .item-right {
		margin-left: 9px;
		width: 100%;
		display: flex;
		flex-flow: column
	}

	.store-list .store-item .info-item .item-right .item {
		display: flex;
		align-items: center;
		justify-content: space-between;
		font-size: 24rpx
	}

	.store-list .store-item .info-item .item-right .item .title {
		color: #333;
		font-size: 34rpx;
		;
		font-weight: 700
	}

	.store-list .store-item .info-item .item-right .item .stock-text {
		color: #ff962a;
		font-weight: 700;
		font-size: 28rpx;
		;
		margin: 0 7px
	}

	.store-list .store-item .info-item .item-right .item .progress {
		width: 125px
	}

	.store-list .store-item .info-item .item-right .item .distance-text {
		color: #bec1c7
	}

	.store-list .store-item .info-item .item-right .item .time-region {
		width: 125px;
		padding: 1px 0;
		color: #fff;
		background-color: #8fc926;
		text-align: center;
		border-radius: 1px
	}

	.store-list .store-item .cashback-item {
		justify-content: space-between;
		align-items: center;
		margin-left: 85px;
	}

	.store-list .store-item .cashback-item .icon {
		width: 19px;
		height: 19px
	}

	.store-list .store-item .cashback-item .discount-text {
		background-color: #f96456;
		color: #fff;
		border-radius: 4px;
		text-align: center;
		line-height: 19px;
		font-size: 12px
	}

	.store-list .store-item .cashback-item .text {
		color: #333;
		font-size: 24rpx
	}

	.store-list .store-item .more-item {
		align-items: center;
		justify-content: center
	}

	.store-list .store-item .more-item .more-text {
		color: #bec1c7;
		font-size: 24rpx;
		margin-right: 7px
	}

	.store-list .store-item .address-item .icon {
		width: 19px;
		height: 19px
	}

	.store-list .store-item .address-item .address-text {
		color: #bec1c7;
		font-size: 24rpx;
		margin-left: 7px
	}

	.store-list .store-item .footer-item {
		padding-bottom: 0;
		color: #f96456;
		align-items: center;
		justify-content: center;
		font-size: 28rpx;
	}

	.menu-navigation {
		height: 100px;
		background-color: #fff;
		margin: 40upx 20upx;
		font-size: 24rpx;
		border-radius: 9px
	}

	.menu-navigation .menu-lg {
		width: 25%;
		display: flex;
		flex-flow: column;
		align-items: center;
		font-size: 28rpx;
		color: #666666;
	}

	.menu-navigation .menu-lg image {
		width: 110rpx;
		height: 110rpx;
		margin: 15rpx 0;
	}

	.menu-navigation .menu-spot {
		width: 4px;
		background-color: #ff8546;
		padding: 3px 4px;
		border-radius: 3px;
		margin-top: 9px
	}

	.menu-navigation .menu-spot-circular {
		width: 4px;
		background-color: #ff8546;
		border-radius: 50%;
		margin-top: 9px;
		margin-left: 4px
	}

	.menu-navigation .add-c-d {
		text-align: center;
		position: relative;
		left: 0;
		right: 0;
		top: -19px
	}

	.limit-store-container {
		background-color: #fff;
		margin: 9px 14px;
		font-size: 24rpx;
		border-radius: 9px
	}

	.page-listHeader {
		font-size: 34rpx;
		font-weight: bold;
		color: #333333;
		padding: 20upx 0;
	}

	.page-otherHeader {
		display: flex;
		align-items: center;
		justify-content: space-between;

		.variety-text {
			padding: 0;
		}

		.variety-navigation {
			margin: 0;
		}
	}

	.limit-store-container .header {
		display: flex;
		justify-content: space-between;
		align-items: center;
		padding: 9px;
		border-radius: 9px 9px 0 0;
		// background: linear-gradient(180deg, #fff0e9 0, #fff)
		background: linear-gradient(180deg, #4bbfff 0, #4bbfff);
		color: #fff;
	}

	.limit-store-container .header .header-icon {
		height: 14px
	}

	.limit-store-container .header .right {
		display: flex;
		align-items: center
	}

	.limit-store-container .header .right .more-text {
		color: #bec1c7
	}

	.limit-store-container .body .scroll-list {
		display: flex;
		align-items: center;
		width: unset;
		margin: 0 9px
	}

	.limit-store-container .body .scroll-list .scroll-item {
		display: flex;
		flex-flow: column;
		margin-top: 9px;
		margin-right: 9px
	}

	.limit-store-container .body .scroll-list .scroll-item .item-row {
		margin-bottom: 4px;
		position: relative
	}

	.limit-store-container .body .scroll-list .scroll-item .item-row .button {
		background: linear-gradient(0deg, #cd3c20, #dc7562);
		font-size: 24rpx;
		color: #fff;
		text-align: center;
		border-radius: 15px;
		transform: scale(0.9);
		transform-origin: right;
		padding: 4rpx 8rpx;
	}

	.limit-store-container .body .scroll-list .scroll-item .item-row .scroll-img {
		width: 160rpx;
		height: 160rpx;
		border-radius: 10rpx
	}

	.limit-store-container .body .scroll-list .scroll-item .item-row .scroll-name {
		width: 93px;
		font-size: 28rpx;
		;
		font-weight: 700
	}

	.limit-store-container .body .scroll-list .scroll-item .item-row .stock-text {
		font-size: 10px
	}

	.limit-store-container .body .scroll-list .scroll-item .item-row .stock {
		color: #f96456
	}

	.limit-store-container .body .scroll-list .scroll-item .item-row .amount-text {
		font-size: 9px;
		color: #fff;
		border-radius: 0 7px 0 7px;
		background: linear-gradient(270deg, #ff8826 0, #ed3066);
		position: absolute;
		padding: 2px 4px;
		text-align: center;
		bottom: 0;
		left: 0
	}

	.limit-store-container .body .scroll-list .scroll-item .item-row .top-left {
		background-color: #fdb82d;
		font-size: 18rpx;
		color: #fff;
		width: 200rpx;
		height: 18px;
		text-align: center;
		line-height: 18px;
		position: absolute;
		top: -3px;
		left: 0;
		overflow: hidden;
		text-overflow: ellipsis;
		white-space: nowrap;
		padding: 0 2px;
		box-sizing: border-box;
		transform: scale(0.8);
		transform-origin: left;
	}

	.limit-store-container .body .scroll-list .scroll-item .item-row .bottom-right {
		font-size: 24rpx;
		color: #fff;
		background-color: #f95428;
		width: 60px;
		height: 18px;
		text-align: center;
		line-height: 18px;
		position: absolute;
		bottom: 0px;
		right: 0px;
		overflow: hidden;
		text-overflow: ellipsis;
		white-space: nowrap;
		padding: 0 2px;
		box-sizing: border-box;
		transform: scale(0.8);
		transform-origin: right;
	}

	.limit-store-container .body .scroll-list .scroll-foot {
		display: flex;
		flex-flow: column;
		align-items: center;
		padding: 4px;
		border-radius: 9px;
		background-color: #f0f0f0
	}

	.limit-store-container .body .scroll-list .scroll-foot .more-icon {
		width: 9px;
		height: 9px;
		padding: 2px;
		border: 1px solid #ebebeb;
		border-radius: 50%;
		margin-bottom: 4px
	}

	.limit-store-container .body .scroll-list .scroll-foot .more-text {
		-webkit-writing-mode: vertical-lr;
		writing-mode: vertical-lr;
		letter-spacing: 2px
	}

	.redPacket {
		margin: 9px 14px;
	}

	.redPacket .item {
		width: 49%;
	}

	.redPacket .item .img {
		width: 100%;
	}
</style>